<!-- @author zhengjie -->
<template>
    <el-dialog class="zt-right-dialog" :visible.sync="open" width="500px" append-to-body @close="closeDialog"
        :fullscreen="true">
        <div class="zt-right-headline flex">
            <div class="zt-right-close cursor flex-left" @click="closeDialog">
                <img src="@/assets/images/right.png" c style="height: 30px;widows: 30px;" >
                <div style="color: #2CA6E0;margin-left: 5px; font-size: 16px;">返回</div>
            </div>
            <div class="flex-rihgt zt-rihgt-title">
                {{ title }}
            </div>

        </div>
        <slot class="zt-dialog-solt"></slot>
    </el-dialog>
</template>
  
<script>
export default {
    name: 'RightDialog',
    props: {
        title: {
            type: String
        },
        visible: {
            type: Boolean,
        },
        type:{
            type: Boolean,
        }
    },
    watch: {
        visible(newValue) {
            // 监听 visible 属性的变化
            this.open = newValue;
        },
        type(newValue){

        }
    },
    data() {
        return {
            name: '',
            open: false,
        }
    },
    methods: {
        closeDialog() {//关闭回调
            this.$emit("closeDialog", false);
        },
    }
}
</script>
  
<style rel="stylesheet/scss" lang="scss" scoped></style>
  